package cn.yuanqiao.archive.liyong.domain;

import cn.yuanqiao.common.annotation.Excel;
import cn.yuanqiao.common.exception.ServiceException;
import cn.yuanqiao.common.utils.StringUtils;
import cn.yuanqiao.common.core.domain.BaseEntity;
import cn.yuanqiao.common.utils.SecurityUtils;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;

import java.util.List;

/**
 * @ProjectName: cn.yuanqiao.archive.liyong.domain
 * @ClassName: YqConsultRegister
 * @Author: lenovo
 * @Description: hbWang
 * @Date: 2024/1/26 15:30
 * @Version: 1.0
 **/
public class YqConsultRegister extends BaseEntity {
    private static final long serialVersionUID = 1L;

    private final String BIGTABLENAME = "_YQ_CONSULT_REGISTER";

    public YqConsultRegister() {
        String tenantCode = SecurityUtils.getTenantCode();
        if (StringUtils.isEmpty(tenantCode)) {
            throw new ServiceException("TenantCode is null");
        } else {
            this.tableName = tenantCode.toUpperCase() + BIGTABLENAME;
        }
    }

    private String tableName;

    /**
     * 主键
     */
    private String id;

    /**
     * 姓名
     */
    @Excel(name = "姓名")
    private String consultName;

    /**
     * 证件号
     */
    @Excel(name = "证件号")
    private String consultNum;

    /**
     * 单位
     */
    @Excel(name = "单位")
    private String nuit;

    /**
     * 证件类型
     */
    @Excel(name = "证件类型")
    private String numType;

    /**
     * 电话
     */
    @Excel(name = "电话")
    private String phone;

    /**
     * 人次
     */
    @Excel(name = "人次")
    private String personNum;

    /**
     * 政治面貌
     */
    @Excel(name = "政治面貌")
    private String politicalOutlook;

    /**
     * 利用目的
     */
    @Excel(name = "利用目的")
    private String utilizeAim;

    /**
     * 查档时间
     */
    @Excel(name = "查档时间")
    private String consultTime;

    /**
     * 用途
     */
    @Excel(name = "用途")
    private String useTo;

    /**
     * 介绍信
     */
    @Excel(name = "介绍信")
    private String introduceLetter;

    /**
     * 创建人id
     */
    @Excel(name = "创建人id")
    private String creatorId;

    /**
     * 删除 (0否 1是)
     */
    @Excel(name = "删除 (0否 1是)")
    private String isDel;

    /**
     * 状态 (0 未提交 1提交)
     */
    @Excel(name = "状态 (0 未提交 1提交)")
    private String state;

    /**
     * 档案信息表主键id集合
     */
    private String cuIds;
    /**
     * 档案信息
     */
    private List<YqDaRegister> yqDaRegisters;

    public String getCuIds() {
        return cuIds;
    }

    public void setCuIds(String cuIds) {
        this.cuIds = cuIds;
    }

    public List<YqDaRegister> getYqDaRegisters() {
        return yqDaRegisters;
    }

    public void setYqDaRegisters(List<YqDaRegister> yqDaRegisters) {
        this.yqDaRegisters = yqDaRegisters;
    }

    public String getTableName() {
        return tableName;
    }

    public void setTableName(String tableName) {
        this.tableName = tableName;
    }

    public void setId(String id) {
        this.id = id;
    }

    public String getId() {
        return id;
    }

    public void setConsultName(String consultName) {
        this.consultName = consultName;
    }

    public String getConsultName() {
        return consultName;
    }

    public void setConsultNum(String consultNum) {
        this.consultNum = consultNum;
    }

    public String getConsultNum() {
        return consultNum;
    }

    public void setNuit(String nuit) {
        this.nuit = nuit;
    }

    public String getNuit() {
        return nuit;
    }

    public void setNumType(String numType) {
        this.numType = numType;
    }

    public String getNumType() {
        return numType;
    }

    public void setPhone(String phone) {
        this.phone = phone;
    }

    public String getPhone() {
        return phone;
    }

    public void setPersonNum(String personNum) {
        this.personNum = personNum;
    }

    public String getPersonNum() {
        return personNum;
    }

    public void setPoliticalOutlook(String politicalOutlook) {
        this.politicalOutlook = politicalOutlook;
    }

    public String getPoliticalOutlook() {
        return politicalOutlook;
    }

    public void setUtilizeAim(String utilizeAim) {
        this.utilizeAim = utilizeAim;
    }

    public String getUtilizeAim() {
        return utilizeAim;
    }

    public void setConsultTime(String consultTime) {
        this.consultTime = consultTime;
    }

    public String getConsultTime() {
        return consultTime;
    }

    public void setUseTo(String useTo) {
        this.useTo = useTo;
    }

    public String getUseTo() {
        return useTo;
    }

    public void setIntroduceLetter(String introduceLetter) {
        this.introduceLetter = introduceLetter;
    }

    public String getIntroduceLetter() {
        return introduceLetter;
    }

    public void setCreatorId(String creatorId) {
        this.creatorId = creatorId;
    }

    public String getCreatorId() {
        return creatorId;
    }

    public void setIsDel(String isDel) {
        this.isDel = isDel;
    }

    public String getIsDel() {
        return isDel;
    }

    public void setState(String state) {
        this.state = state;
    }

    public String getState() {
        return state;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE)
                .append("id", getId())
                .append("consultName", getConsultName())
                .append("consultNum", getConsultNum())
                .append("nuit", getNuit())
                .append("numType", getNumType())
                .append("phone", getPhone())
                .append("personNum", getPersonNum())
                .append("politicalOutlook", getPoliticalOutlook())
                .append("utilizeAim", getUtilizeAim())
                .append("consultTime", getConsultTime())
                .append("useTo", getUseTo())
                .append("remark", getRemark())
                .append("introduceLetter", getIntroduceLetter())
                .append("creatorId", getCreatorId())
                .append("createTime", getCreateTime())
                .append("isDel", getIsDel())
                .append("state", getState())
                .toString();
    }
}
